<?php
$this->breadcrumbs=array(
	'Apps Comments'=>array('index'),
	'Manage',
);

$this->menu=array(
	array('label'=>'List AppsComments', 'url'=>array('index')),
	array('label'=>'Create AppsComments', 'url'=>array('create')),
);

Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
	$('.search-form').toggle();
	return false;
});
$('.search-form form').submit(function(){
	$.fn.yiiGridView.update('apps-comments-grid', {
		data: $(this).serialize()
	});
	return false;
});
");
?>

<h1>Manage Apps Comments</h1>

<?php echo CHtml::link('查找','#',array('class'=>'search-button')); ?>
<div class="search-form" style="display:none">
<?php $this->renderPartial('_search',array(
	'model'=>$model,
	'cnstatus' => $cnstatus ,
)); ?>
</div><!-- search-form -->

<?php $this->widget('zii.widgets.grid.CGridView', array(
	'id'=>'apps-comments-grid',
	'dataProvider'=>$model->search(),
	'columns'=>array(
		'comment_id',
array(
		'name'=>'app_id',
		'type'=>'raw',
		'value'=>array($this, 'showApps')
),
array(
		'name'=>'user_id',
		'type'=>'raw',
		'value'=>array($this, 'showUsers')
),

array(
		'name'=>'status',
		'type'=>'raw',
		'value'=>array($this, 'showStatus')
),
// 		'content',
// 		'reply_id',
// 		'rating',
		'ctime',
// 		'status',
// 		'mtime',
		array(
			'class'=>'CButtonColumn',
			'template'=>'{view} {delete}',
		),
	),
)); ?>
